//
//  ZBThreeCollectionViewCell.m
//  MoBan
//
//  Created by apple on 16/7/8.
//  Copyright © 2016年 apple. All rights reserved.
//

#import "ZBThreeCollectionViewCell.h"
@interface ZBThreeCollectionViewCell()
@property(nonatomic,strong)UILabel *nalelable;
@property(nonatomic,strong)UILabel *detailLable;
@property(nonatomic,strong)UIImageView *imageview;
@end
@implementation ZBThreeCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self addUI];
    }
    return self;
}
/**
 添加ui
 
 */
-(void)addUI
{
    self.nalelable = [[UILabel alloc]init];
    [self.contentView addSubview:self.nalelable];
    
    self.detailLable = [[UILabel alloc]init];
    [self.contentView addSubview:self.detailLable];
    
    self.imageview = [[UIImageView alloc]init];
    [self.contentView addSubview:self.imageview];

}
-(void)layoutSubviews
{
    [super layoutSubviews];
    
    self.nalelable.frame = CGRectMake(10*Kscr, 5*Kscr, self.width/2, 20*Kscr);
    
    self.detailLable.frame = CGRectMake(10*Kscr, self.nalelable.bottom+5*Kscr, self.width/2, 20*Kscr);
    
    self.imageview.frame = CGRectMake(self.width/2+5*Kscr, 5*Kscr, self.width/2-10*Kscr, self.height-10*Kscr);
}
-(void)ZBSetThreedasouce:(NSString *)str
{

    self.nalelable.text = @"热门团购";
    self.detailLable.text = @"热门团购";
    self.imageview.image = [UIImage imageNamed:@"text.png"];
    
//    self.nalelable.text =str;
    NSLog(@"第三个%@",str);
}
@end
